#!/usr/bin/env node

const {Readable}=require('stream');
//等价于const Read = require('stream').Readable

const rs=new Readable();

let c='a'.charCodeAt(0);

//重写read方法：拉取流
rs._read=()=>{
  //rs.push("hello");
  
  rs.push(String.fromCharCode(c++));
  if(c==='z'.charCodeAt(0)+1) rs.push(null);
  
}

rs.pipe(process.stdout);
//将流接入到标准输出流


